<template>
  <div id="codeModelManagement" v-loading = "loading" element-loading-text = "数据正在加载中">

    <div class="top-div">
      <Top @selectCodeModel="selectCodeModel" />
    </div>

    <div class="center-div">
      <Table :tableCodeModelData="tableCodeModelData" @changeLoad="changeLoad" @selectCodeModel="selectCodeModel" />
    </div>

    <div class="bottom-div">
      <Bottom @tableCodeModelDataFun="tableCodeModelDataFun" @changeLoad="changeLoad" :selectParams = "selectParams" />
    </div>

  </div>
</template>

<script>
import Top from './components/top.vue'
import Table from './components/table.vue';
import Bottom from './components/bottom.vue';
import Add from './components/add.vue';
import Edit from './components/edit.vue';

export default {
    name: "codeModelManagement",
    data() {
      return {
        text: [],
        tableCodeModelData: [],
        loading: false,
        dialogFormVisible: false,
        selectParams: {}
      };
    },
    methods: {
      tableCodeModelDataFun(formData) {
        this.tableCodeModelData = formData 
      },
      changeLoad(load){
        this.loading = load
      },
      selectCodeModel(params) {
        this.selectParams = JSON.parse(JSON.stringify(params))
      }
    },
    components: { Top, Table, Bottom, Add, Edit}
}
</script>

<style scoped lang="scss"> 

.top-div{
  display: inline-block;
  margin: 20px;
}

.center-div {

}

.bottom-div {
  height: 5vh;
}

 
</style>
